package com.musicserver.controller;

import com.musicserver.common.R;
import com.musicserver.model.request.UserSupportRequest;
import com.musicserver.service.UserSupportService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/userSupport")
public class UserSupportController {
    @Autowired
    private UserSupportService userSupportService;

    // 提交评论
    @PostMapping("/like")
    public R addComment(@RequestBody UserSupportRequest userSupportRequest) {
        return userSupportService.toSupport(userSupportRequest);
    }
}
